from flask import Flask,render_template
# from gevent import pywsgi
# 创建一个对象实例
app=Flask(__name__)
# 给定访问路径
@app.route("/")
def index():
    return render_template("index.html")
@app.route("/food")
def myFood():
    return render_template("food.html")
@app.route("/play")
def myPlay():
    return render_template("play.html")
@app.route("/drink")
def myDrink():
    return render_template("drink.html")
@app.route("/pet")
def myPet():
    return render_template("pet.html")

# def print_hi(name):
#     # Use a breakpoint in the code line below to debug your script.
#     print(f'Hi, {name}')  # Press Ctrl+F8 to toggle the breakpoint.
#

# 运行app实例
if __name__ == '__main__':
    # server = pywsgi.WSGIServer(('127.0.0.1', 5000), app)
    # server.serve_forever()
    app.run(host="0.0.0.0",port=8080)